﻿<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <title>事件登记</title>
    <meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />

    <script src="components/requirejs/require.js" data-main="resources/js/incidentNew2" async="async"></script>
    <link href="components/mint-ui/style.min.css" rel="stylesheet" />
    <link href="resources/css/common.css" rel="stylesheet" />
    <link href="resources/css/incidentNew.css" rel="stylesheet" />
</head>
<body>
    <div id="view">
        <div view v-if="isloading"></div>

        <div warning center>
            <div center>
                <img src="resources/image/incidentNew/warning.png" />
            </div>
            <div>
                若涉嫌机密信息，请使用网页或者电话报单方式
            </div>
        </div>
        <div group>
            <div group-title>
                <div center-v>
                    <img src="resources/image/common/image.png" />
                </div>
                <div>
                    图片上传
                </div>
                <div center>
                    <div arrow-up></div>
                </div>
            </div>
            <div upload center-v>
                <img v-for="item in images" v-bind:src="item.data" />
                <div file v-if="images.length < 3">
                    <input type="file" v-on:change="imgUpload($event)" />
                </div>
            </div>
        </div>

        <div group>
            <div group-title>
                <div center-v>
                    <img src="resources/image/common/personalInfo.png" />
                </div>
                <div>
                    个人信息
                </div>
                <div center>
                    <div arrow-up></div>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>请求人：</div>
                <search title="请求人" treeurl="/common/customerDepartment" listurl="/common/user?department_path=" v-model="cusUser" v-on:input="cusUserChange" :autoload=true></search>
            </div>
            <div group-item>
                <div>联系人：</div>
                <div>
                    <input type="text" v-model="others.linkmanName" />
                </div>
            </div>
            <div group-item>
                <div>电话：</div>
                <div>
                    <input type="text" v-model="others.userTel" />
                </div>
            </div>
            <div group-item>
                <div>联系方式：</div>
                <div>
                    <input type="text" v-model="others.userMobile" />
                </div>
            </div>
            <div group-item>
                <div>邮箱：</div>
                <div>
                    <input type="text" v-model="others.userEmail" />
                </div>
            </div>
        </div>

        <div group>
            <div group-title>
                <div center-v>
                    <img src="resources/image/common/incidentInfo.png" />
                </div>
                <div>
                    事件信息
                </div>
                <div center>
                    <div arrow-up></div>
                </div>
            </div>
            <div group-item>
                <div>事件性质：</div>
                <div>
                    <select v-model="data.incidentType">
                        <option value="故障">故障</option>
                        <option value="问询">问询</option>
                        <option value="反馈">反馈</option>
                        <option value="需求">需求</option>
                    </select>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>标题：</div>
                <div>
                    <input type="text" v-model="data.title" />
                </div>
            </div>
            <div group-item>
                <textarea placeholder="*请输入事件详细描述" v-model="data.description"></textarea>
                <div voice v-on:touchstart="startVoice($event)" v-on:touchend="endVoice($event)"></div>
            </div>
            <div group-item>
                <div>归属项目：</div>
                <div>
                    <select v-model="data.projectId">
                        <option v-for="item in project" v-bind:value="item.id">{{item.name}}</option>
                    </select>
                </div>
            </div>
            <div group-item>
                <div>关联资产：</div>
                <search title="关联资产" treeurl="/common/ciCategory" listurl="/common/ci?path=" v-model="ci"></search>
            </div>
            <div group-item>
                <div>发生时间：</div>
                <datetime v-model="data.happenTime"></datetime>
            </div>
            <div group-item>
                <div>期望完成时间：</div>
                <datetime v-model="data.expectTime"></datetime>
            </div>
            <div group-item>
                <div>发生频率：</div>
                <div>
                    <dictionary type="OCCURRENCE_FREQUENCY" v-model="data.occurrenceFrequency"></dictionary>
                </div>
            </div>
        </div>

        <div group>
            <div group-title>
                <div center-v>
                    <img src="resources/image/common/incidentInfo.png" />
                </div>
                <div>
                    分类信息
                </div>
                <div center>
                    <div arrow-up></div>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>事件分类：</div>
                <search title="事件分类" treeurl="/common/category" v-model="icd_category"></search>
            </div>
            <div group-item>
                <div><span required>*</span>紧急度：</div>
                <div>
                    <dictionary type="INCIDENT_URGENCY" v-model="data.urgencyName"></dictionary>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>影响度：</div>
                <div>
                    <dictionary type="INCIDENT_EFFECT" v-model="data.effectName"></dictionary>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>优先级：</div>
                <div>
                    <dictionary type="INCIDENT_PRIORITY" v-model="data.priorityName"></dictionary>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>处理方式：</div>
                <div>
                    <select v-model="data.dealType">
                        <option value="1">直接处理</option>
                        <option value="2">分派处理</option>
                    </select>
                </div>
            </div>
            <div group-item v-if="data.dealType == 2">
                <div><span required>*</span>支持人员：</div>
                <search title="支持人员" treeurl="/common/userDepartment" listurl="/common/user?department_path=" v-model="supporter"></search>
            </div>
        </div>

        <div group v-if="data.dealType == 1">

            <div input-item textarea>
                <div>
                    <div center>
                        <img src="resources/image/backlogDetail/reasonAnalyze.png" />
                    </div>
                    <div><span required>*</span>
                        原因分析
                    </div>
                </div>
                <div>
                    <textarea type="text" placeholder="请输入原因分析..." v-model="data.reasonAnalyze"></textarea>
                </div>
            </div>

            <div input-item textarea>
                <div>
                    <div center>
                        <img src="resources/image/backlogDetail/solution.png" />
                    </div>
                    <div><span required>*</span>
                        解决方案
                    </div>
                </div>
                <div>
                    <textarea type="text" placeholder="请输入解决方案..." v-model="data.solution"></textarea>
                </div>
            </div>

            <div input-item textarea>
                <div>
                    <div center>
                        <img src="resources/image/backlogDetail/handleProcess.png" />
                    </div>
                    <div><span required>*</span>
                        处理过程
                    </div>
                </div>
                <div>
                    <textarea type="text" placeholder="请输入处理过程..." v-model="data.handleProcess"></textarea>
                </div>
            </div>
        </div>

        <div group v-if="data.dealType == 1">
            <div group-title>
                <div center-v>
                    <img src="resources/image/common/incidentInfo.png" />
                </div>
                <div>
                    关闭信息
                </div>
                <div center>
                    <div arrow-up></div>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>关闭码：</div>
                <div>
                    <dictionary type="INCIDENT_CLOSECODE" v-model="data.closeCode"></dictionary>
                </div>
            </div>
            <div group-item>
                <div><span required>*</span>满意度：</div>
                <div>
                    <dictionary type="INCIDENT_SATISFICATION" v-model="data.satisfaction" :code=true></dictionary>
                </div>
            </div>

            <div input-item textarea>
                <div>
                    <div center>
                    </div>
                    <div>
                        客户意见
                    </div>
                </div>
                <div>
                    <textarea type="text" placeholder="请输入客户意见..." v-model="data.customerOpinion"></textarea>
                </div>
            </div>
        </div>

        <div placeholder-bottombar>
        </div>
        <div bottombar>
            <input type="button" blue value="提交" v-on:click="submit" />
        </div>
    </div>
</body>
</html>